import numpy as np

np.random.seed(2021)


def gen_fake_data():
    fake_data = np.random.rand(1, 3, 320, 320).astype(np.float32) - 0.5
    np.save("fake_data.npy", fake_data)

    # max_labels = 120,类别，
    # fake_label.shape=[n,max_labels,5]
    batchsize = 1
    max_labels = 40
    cls = (np.random.rand(batchsize, max_labels, 1) * 80).astype(np.int)
    box = (np.random.rand(batchsize, max_labels, 4) * 320).astype(np.float32)
    fake_label = np.concatenate((cls, box), axis=2)
    np.save("fake_label.npy", fake_label)


if __name__ == "__main__":
    gen_fake_data()
